home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 10002 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  3.6 KB

  1. Path: camelot.dsccc.com!not-for-mail
  2. From: kcline@sun152.spd.dsccc.com (Kevin Cline)
  3. Newsgroups: comp.lang.ada,comp.lang.c,comp.lang.c++,comp.edu
  4. Subject: Re: C/C++ knocks the crap out of Ada
  5. Date: 5 Mar 1996 10:51:25 -0600
  6. Organization: DSC Communications Corporation Switch Products Division
  7. Message-ID: <4hhred$1rn@sun152.spd.dsccc.com>
  8. References: <JSA.96Feb16135027@organon.com> <4h8r0v$1c4i@saba.info.ucla.edu> <4hbj2b$cnt@sun152.spd.dsccc.com> <adaworksDnrqsE.LpC@netcom.com>
  9. NNTP-Posting-Host: sun152.spd.dsccc.com
  10.  
  11. In article <adaworksDnrqsE.LpC@netcom.com>,
  12. AdaWorks <adaworks@netcom.com> wrote:
  13. >Kevin Cline (kcline@sun152.spd.dsccc.com) wrote:
  14. >
  15. >: In article <4h8r0v$1c4i@saba.info.ucla.edu>,
  16. >: Jay Martin <jmartin@cs.ucla.edu> wrote:
  17. >: >kcline@sun152.spd.dsccc.com (Kevin Cline) writes:
  18. >: >
  19. >: I didn't say that; I said that Ada was not suitable for most software
  20. >: development because Ada programs that did serious work could not
  21. >: be ported.  Actually, I have used Ada-83 to build a good-sized application
  22. >: (50K SLOC) and there is a lot I liked about it.  But porting that application
  23. >: from SunOS to SGI IRIX was much more difficult than porting comparable C++
  24. >: programs.  For whatever reason, the Ada-83 standard simply did not go
  25. >: far enough.  
  26. >
  27. >  How odd.  
  28. >
  29. >  Many of have exactly the opposite experience. It is true that one can
  30. >  write Ada programs that are non-portable.  It is also true that a 
  31. >  correctly designed Ada program will be as portable as a program 
  32. >  written in any other language.
  33. >  The trick is designing at the right level of abstraction. Machine and
  34. >  operating system dependencies should not be the controlling factor in
  35. >  designing an application.  Unless, of course, the targeted application
  36. >  is, itself, a binding to some such dependency.  
  37. >
  38.  
  39. Well, I will now enumerate the difficulties I had porting an Ada program
  40. with a Motif user interface from the TeleSoft compiler for Sparc-SunOS to
  41. the Verdix compiler for MIPS/IRIX circa 1990:
  42.  
  43. 1. The TeleSoft compiler came with the IEEE Ada-POSIX bindings.
  44.    The Verdix compiler did not; instead it supported a Verdix-defined
  45.    API for UNIX services that was radically different.
  46.       
  47. 2. The syntax (pragmas) required to call C code from the two compilers 
  48.    differed.
  49.  
  50. 3. Although both compilers were 'validated', they both failed to compile
  51.    certain LRM-comformant code, and generated erroneous object code in
  52.    some other cases.  I concluded that the Ada validation suite
  53.    was rather incomplete, and actually proved very little about compiler
  54.    quality.
  55.    
  56. 4. The debuggers were extremely poor and buggy when compared to dbx.
  57.    In particular, the user interface to the Verdix debugger was one
  58.    of the most bizarre I have ever seen.
  59.  
  60. 6. Because Ada-83 did not allow passing procedures as parameters to
  61.    other procedures, there was no reasonable way to create an
  62.    API to an event-driven GUI library like MOTIF.
  63.  
  64. 5. The compilers had two completely different API's for calling 
  65.    X and MOTIF services.
  66.  
  67. The lack of industry standard Ada bindings to these common OS
  68. services combined with the high expense and poor quality of the
  69. available Ada-83 compilers made development a medium-scale portable
  70. UNIX application in Ada much more expensive and difficult than
  71. developing the same application in C.
  72.  
  73. Perhaps the emergence of GNAT has changed all this, but it is going
  74. to be hard for Ada to keep up.  To use Ada in my work today, I would 
  75. require an API to CORBA, Tcl/Tk, and the Solaris real-time facilities
  76. (itimers, etc.) and a runtime that efficiently mapped Ada tasks to 
  77. Solaris threads.
  78. -- 
  79. Kevin Cline
  80.